using System.Text.RegularExpressions;

namespace TLDRML.Tokens
{
    public class EqualsToken : Token
    {
        public EqualsToken(TokenPosition position) : base(position)
        {
        }

        public override string ToString()
        {
            return "[EQUALS]";
        }
    }

    public class EqualsTokenDefinition : TokenDefinition
    {
        public EqualsTokenDefinition() 
            : base(new Regex("=", RegexOptions.Compiled))
        {
        }

        public override Token Create(TokenPosition tokenPosition, string value)
        {
            return new EqualsToken(tokenPosition);
        }
    }
}